﻿namespace Driven.ProcessScheduler.Interfaces
{
    /// <summary>
    /// Implement this interface in the component you would like to schedule
    /// </summary>
    public interface IScheduledComponent
    {
        /// <summary>
        /// Fires on a given schedule, configured the the application configuration file
        /// </summary>
        /// <returns>A list of messages (error or information) to write to the log</returns>
        string[] Execute();

        /// <summary>
        /// This should return the name of your component, it will be used for logging messages
        /// </summary>
        string ToString();
    }
}